
#ifndef _AbstractManager_H_
#define _AbstractManager_H_


#include "CoreApi.hpp"
#include "AbstractObject.hpp"
#include <QString>

namespace NSCore {

	using ObjectMap = QMap<QString /*name*/, AbstractObject* /*objects*/>;

	class COREAPI AbstractManager :
		public QObject,
		public AbstractObject
	{
		Q_OBJECT
	private:

	protected:
		ObjectMap m_objects;
	public:
		AbstractManager();
		virtual ~AbstractManager();

	public:
		virtual int getObjectSize() { return m_objects.size(); };
		virtual AbstractObject* getObject(QString name);
		virtual void registerObject(AbstractObject* ins);
		virtual inline ObjectMap getObjects() { return m_objects; };
		virtual inline QString className() override { return "AbstractManager"; };


	};

}

#endif // !_ABS_FACTORY_H_
